package com.sg.model.oms.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import com.sg.framework.common.po.BaseEntity;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serial;
import java.io.Serializable;
import java.io.Serial;
import java.util.Date;

/**
 * 备注：编制创建入口，有两种，a，自由型在部门设置成员处生成就职记录同时生成或选择编制ID，自由型只有组织ID与部门ID记录； b，严格型岗位处，严格型，选择职务ID；
 * 4、有空间，有应用
 *
 * @author xxx
 */
@Data
@Accessors(chain = true)
@TableName("oms_org_staffing") //1-3-15编制表（07）
public class Staffing implements Serializable {
    @Serial
    private static final long serialVersionUID = 1L;


    /**
     * 编制ID
     */
    @TableId(value = "staffing_id", type = IdType.ASSIGN_UUID)
    @NotNull(message = "staffingId不能为空")
    private String staffingId;
    /**
     * 编制编号
     */
    @TableField(value = "staffing_number")
    @NotNull(message = "编制编号不能为空")
    @Schema(description = "编制编号")
    private String staffingNumber;
    /**
     * 编制是否在职 TRUE:是 FALSE:否
     */
    @TableField(value = "induction_state")
    @Schema(description = "编制是否在职")
    private String inductionState;
    /**
     * 组织ID
     */
    @TableField(value = "organization_id")
    @NotNull(message = "组织ID不能为空")
    @Schema(description = "组织ID")
    private String organizationId;
    /**
     * 是否自动创建 TRUE:是 FALSE:否
     */
    @TableField(value = "is_auto_create")
    @Schema(description = "是否自动创建")
    private String isAutoCreate;
    /**
     * 部门ID
     */
    @TableField(value = "dept_id")
    @Schema(description = "部门ID")
    private String deptId;
    /**
     * 是否兼职编制 TRUE:是 FALSE:否
     */
    @TableField(value = "is_part_time_staffing")
    @NotNull(message = "是否兼职编制不能为空")
    @Schema(description = "是否兼职编制")
    private String isPartTimeStaffing;
    /**
     * 职务ID
     */
    @TableField(value = "position_id")
    @NotNull(message = "职务ID不能为空")
    @Schema(description = "职务ID")
    private String positionId;
    /**
     * 是否兼职占用 TRUE:是 FALSE:否
     */
    @TableField(value = "is_usedby_part_time")
    @Schema(description = "是否兼职占用")
    private String isUsedbyPartTime;
    /**
     * 编制账户ID
     */
    @TableField(value = "staffing_account_id")
    @Schema(description = "编制账户ID")
    private String staffingAccountId;
    /**
     * 临时锁定状态 TRUE:是 FALSE:否
     */
    @TableField(value = "temp_lock")
    @NotNull(message = "临时锁定状态不能为空")
    @Schema(description = "临时锁定状态")
    private String tempLock;
    /**
     * 主体生命周期 CURRENTLY_VALID:当前有效 EDITING:正在编辑 ARCHIVING:历史存档
     */
    @TableField(value = "subject_life_cycle")
    @NotNull(message = "主体生命周期不能为空")
    @Schema(description = "主体生命周期")
    private String subjectLifeCycle;
    /**
     * 是否存档 TRUE:是 FALSE:否
     */
    @TableField(value = "is_archive")
    @NotNull(message = "是否存档不能为空")
    @Schema(description = "是否存档")
    private String isArchive;
    /**
     * 操作人就职记录ID
     */
    @TableField(value = "operation_induction_id")
    @NotNull(message = "操作人就职记录ID不能为空")
    @Schema(description = "操作人就职记录ID")
    private String operationInductionId;
    /**
     * 创建人就职记录ID
     */
    @TableField(value = "create_induction_id")
    @NotNull(message = "创建人就职记录ID不能为空")
    @Schema(description = "创建人就职记录ID")
    private String createInductionId;
    /**
     * 发布人就职记录ID
     */
    @TableField(value = "release_induction_id")
    @Schema(description = "发布人就职记录ID")
    private String releaseInductionId;
    /**
     * 存档人就职记录ID
     */
    @TableField(value = "archive_induction_id")
    @Schema(description = "存档人就职记录ID")
    private String archiveInductionId;
    /**
     * 操作时间
     */
    @TableField(value = "operate_time")
    @NotNull(message = "操作时间不能为空")
    @Schema(description = "操作时间")
    private Date operateTime;
    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    @NotNull(message = "创建时间不能为空")
    @Schema(description = "创建时间")
    private Date createTime;
    /**
     * 发布时间
     */
    @TableField(value = "release_time")
    @Schema(description = "发布时间")
    private Date releaseTime;
    /**
     * 存档时间
     */
    @TableField(value = "archive_time")
    @Schema(description = "存档时间")
    private Date archiveTime;
    /**
     * 是否作废 TRUE:是 FALSE:否
     */
    @TableField(value = "is_valid")
    @NotNull(message = "是否作废不能为空")
    @Schema(description = "是否作废")
    private String isValid;
    /**
     * 创建于空间ID
     */
    @TableField(value = "space_id")
    @NotNull(message = "创建于空间ID不能为空")
    @Schema(description = "创建于空间ID")
    private String spaceId;
    /**
     * 创建于联盟应用ID
     */
    @TableField(value = "app_id")
    @NotNull(message = "创建于联盟应用ID不能为空")
    @Schema(description = "创建于联盟应用ID")
    private String appId;
}
